<!--/**
* 举报*
*
* @author LWG
* @date 2022/9/20 15:10
* @since 1.0.0
*/-->
<template>
  <div>
    <van-nav-bar
      title="重置密码"
      left-text="返回"
      @click-left="onClickLeft"
      left-arrow
      style="margin-bottom: 6px"
    />
    <van-form @submit="onSubmit" style="padding-right: 6px">
      <van-cell-group>
        <van-field v-model="value" label="旧密码" placeholder="请输入旧密码" />
      </van-cell-group>
      <van-field
        v-model="pasword"
        rows="1"
        autosize
        label="新密码"
        type="textarea"
        placeholder="请输入新密码"
      />
      <van-field v-model="pasword2" label="确认密码" placeholder="请再次输入新密码" />
      <van-popup
        v-model="showPicker"
        position="bottom"
        style="border-radius: 15px 15px 0 0"
      >
        <van-picker
          show-toolbar
          :columns="columns"
          @confirm="onConfirm"
          @cancel="showPicker = false"
        />
      </van-popup>
      
      <div style="margin: 16px">
        <van-button round block type="info" native-type="submit"
          >修改</van-button
        >
      </div>
    </van-form>
  </div>
</template>

<script>
import { Toast } from "vant";

export default {
  name: "PostShare",
  data() {
    return {
      value: "",
      pasword: "",
      pasword2: '',
      selectValue: "",
      showPicker: false,
    };
  },
  methods: {
    onClickLeft() {
      Toast("返回");
      history.go(-1)
    },
    onSubmit(values) {
      console.log("submit", values);
    },
    onConfirm(selectValue) {
      this.selectValue = selectValue;
      this.showPicker = false;
    },
  },
};
</script>

<style scoped>
</style>